home *** CD-ROM | disk | FTP | other *** search
/ Macworld Expo - Develope…Central & Net Innovations / Developer Central and Net Innovators (MacWorld Expo) (January 1999).iso / Developer Central / Bowers Development / Demo AppMaker / Examples / C⁄C++ OS8 / Gadgets / DDocData.h < prev    next >
Encoding:
Text File  |  1998-09-06  |  4.0 KB  |  168 lines  |  [TEXT/CWIE]

  1. // DDocData -- data class for Gadgets
  2.  
  3. #pragma once
  4.  
  5. #include "AMSignaler.h"
  6.  
  7.  
  8. const long    idTriangle        = 'Trie';
  9. const long    idLeftRight        = 'Left';
  10. const long    idRadios        = 'Rads';
  11. const long    idBars        = 'Bars';
  12. const long    idStandard2        = 'Sta2';
  13. const long    idGraphic        = 'Grac';
  14. const long    idSlider        = 'Slir';
  15. const long    idTickMarks        = 'Tics';
  16. const long    idNonDirectional        = 'Nonl';
  17. const long    idLittleArrows        = 'Lits';
  18. const long    idSpinner        = 'Spir';
  19. const long    idVolumeControl        = 'Voll';
  20. const long    idJimSSlider        = 'Jimr';
  21. const long    idStandard3        = 'Sta3';
  22. const long    idIndeterminate        = 'Inde';
  23. const long    idChasingArrows        = 'Chas';
  24. const long    idRectangle        = 'Rece';
  25. const long    idRoundRect        = 'Rout';
  26. const long    idBarberPole        = 'Bare';
  27. const long    idRoundBarber        = 'Rour';
  28. const long    idSmall        = 'Smal';
  29. const long    idLarge        = 'Lare';
  30. const long    idX12345        = 'X145';
  31. const long    idX12345e6        = 'X126';
  32. const long    idPassword        = 'Pasd';
  33. const long    idDate        = 'Date';
  34. const long    idTime        = 'Time';
  35. const long    idStyled        = 'Styd';
  36.  
  37. class AMEngine;
  38.  
  39. //----------
  40. class DDocData : public AMSignaler {
  41. public:
  42.                 DDocData ();
  43.     virtual        ~DDocData ();
  44.  
  45. public:
  46.     void        ReadFromFile    (AMEngine*        engine);
  47.     void        WriteToFile        (AMEngine*        engine);
  48.  
  49. public:
  50.     Boolean        GetTriangle () const;
  51.     void        SetTriangle    (Boolean        inValue);
  52.  
  53.     Boolean        GetLeftRight () const;
  54.     void        SetLeftRight    (Boolean        inValue);
  55.  
  56.     SInt16        GetRadios () const;
  57.     void        SetRadios    (SInt16        inValue);
  58.  
  59.     UInt16        GetBars () const;
  60.     void        SetBars    (UInt16        inValue);
  61.  
  62.     SInt16        GetStandard2 () const;
  63.     void        SetStandard2    (SInt16        inValue);
  64.  
  65.     SInt16        GetGraphic () const;
  66.     void        SetGraphic    (SInt16        inValue);
  67.  
  68.     SInt16        GetSlider () const;
  69.     void        SetSlider    (SInt16        inValue);
  70.  
  71.     SInt16        GetTickMarks () const;
  72.     void        SetTickMarks    (SInt16        inValue);
  73.  
  74.     SInt16        GetNonDirectional () const;
  75.     void        SetNonDirectional    (SInt16        inValue);
  76.  
  77.     SInt16        GetLittleArrows () const;
  78.     void        SetLittleArrows    (SInt16        inValue);
  79.  
  80.     SInt16        GetSpinner () const;
  81.     void        SetSpinner    (SInt16        inValue);
  82.  
  83.     SInt16        GetVolumeControl () const;
  84.     void        SetVolumeControl    (SInt16        inValue);
  85.  
  86.     SInt16        GetJimSSlider () const;
  87.     void        SetJimSSlider    (SInt16        inValue);
  88.  
  89.     SInt16        GetStandard3 () const;
  90.     void        SetStandard3    (SInt16        inValue);
  91.  
  92.     SInt16        GetIndeterminate () const;
  93.     void        SetIndeterminate    (SInt16        inValue);
  94.  
  95.     SInt16        GetChasingArrows () const;
  96.     void        SetChasingArrows    (SInt16        inValue);
  97.  
  98.     SInt16        GetRectangle () const;
  99.     void        SetRectangle    (SInt16        inValue);
  100.  
  101.     SInt16        GetRoundRect () const;
  102.     void        SetRoundRect    (SInt16        inValue);
  103.  
  104.     SInt16        GetBarberPole () const;
  105.     void        SetBarberPole    (SInt16        inValue);
  106.  
  107.     SInt16        GetRoundBarber () const;
  108.     void        SetRoundBarber    (SInt16        inValue);
  109.  
  110.     StringPtr    GetSmall    (Str255        outStr = nil) const;
  111.     void        SetSmall    (Str255        inValue);
  112.     void        SetSmall    (CharsHandle    inValue);
  113.  
  114.     StringPtr    GetLarge    (Str255        outStr = nil) const;
  115.     void        SetLarge    (Str255        inValue);
  116.     void        SetLarge    (CharsHandle    inValue);
  117.  
  118.     SInt32        GetX12345 () const;
  119.     void        SetX12345    (SInt32        inValue);
  120.  
  121.     double        GetX12345e6 () const;
  122.     void        SetX12345e6    (double        inValue);
  123.  
  124.     StringPtr    GetPassword    (Str255        outStr = nil) const;
  125.     void        SetPassword    (Str255        inValue);
  126.     void        SetPassword    (CharsHandle    inValue);
  127.  
  128.     LongDateRec        GetDate () const;
  129.     void        SetDate    (LongDateRec        inValue);
  130.  
  131.     LongDateRec        GetTime () const;
  132.     void        SetTime    (LongDateRec        inValue);
  133.  
  134.     StringPtr    GetStyled    (Str255        outStr = nil) const;
  135.     void        SetStyled    (Str255        inValue);
  136.     void        SetStyled    (CharsHandle    inValue);
  137.  
  138. protected:
  139.     Boolean        mTriangle;
  140.     Boolean        mLeftRight;
  141.     SInt16        mRadios;
  142.     UInt16        mBars;
  143.     SInt16        mStandard2;
  144.     SInt16        mGraphic;
  145.     SInt16        mSlider;
  146.     SInt16        mTickMarks;
  147.     SInt16        mNonDirectional;
  148.     SInt16        mLittleArrows;
  149.     SInt16        mSpinner;
  150.     SInt16        mVolumeControl;
  151.     SInt16        mJimSSlider;
  152.     SInt16        mStandard3;
  153.     SInt16        mIndeterminate;
  154.     SInt16        mChasingArrows;
  155.     SInt16        mRectangle;
  156.     SInt16        mRoundRect;
  157.     SInt16        mBarberPole;
  158.     SInt16        mRoundBarber;
  159.     Str255        mSmall;
  160.     Str255        mLarge;
  161.     SInt32        mX12345;
  162.     double        mX12345e6;
  163.     Str255        mPassword;
  164.     LongDateRec        mDate;
  165.     LongDateRec        mTime;
  166.     Str255        mStyled;
  167. };
  168.